<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<base href="<%=basePath%>">
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	<title>用户消费冲值记录</title>
<style type="text/css">
<!--
body {
	margin-left: 3px;
	margin-top: 0px;
	margin-right: 3px;
	margin-bottom: 0px;
}
.STYLE1 {
	color: #e1e2e3;
	font-size: 12px;
}
.STYLE6 {color: #000000; font-size: 12; }
.STYLE10 {color: #000000; font-size: 12px; }
.STYLE19 {
	color: #344b50;
	font-size: 12px;
}
.STYLE21 {
	font-size: 12px;
	color: #3b6375;
}
.STYLE22 {
	font-size: 12px;
	color: #295568;
}
A:active,A:visited,A:link {
	COLOR: #0629FD;
	TEXT-DECORATION: none
}

A:hover {
	COLOR: #FF6600;
	TEXT-DECORATION: none
}

A.relatelink:active,A.relatelink:visited,A.relatelink:link { 
	color: white;
	TEXT-DECORATION: none
}

A.relatelink:hover {
	COLOR: #FF6600;
	TEXT-DECORATION: none
}

td {
	font-size: 12px;
	color: #003366;
	height:24px
}

.STYLE1 a{
	COLOR: white;
}
.STYLE1 A:active,.STYLE1 A:visited,.STYLE1 A:link {
	COLOR: white;
	TEXT-DECORATION: none
}
.STYLE1 a:hover{
	COLOR: red;
}
.buttom{
	padding:1px 10px;
	font-size:12px;
	border:1px #1E7ACE solid;
	background:#D0F0FF;
}
-->
</style>

</head>
<body>
<table width="80%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
   <td>
   		<h3><b>${cardno}</b>消费冲值记录</h3>
   </td>
  </tr>
  <tr>
    <td>
    <table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#a8c7ce">
      <tr>
        <td width="15%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="left"><span class="STYLE10">卡号</span></div></td>
        <td width="10%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="left"><span class="STYLE10">会员名</span></div></td>
        <td width="10%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="left"><span class="STYLE10">状态</span></div></td>
        <td width="10%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="right"><span class="STYLE10">金额&nbsp;</span></div></td>
        <td width="15%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="right"><span class="STYLE10">日期&nbsp;</span></div></td>
        <td width="10%" height="20" bgcolor="d3eaef" class="STYLE6"><div align="left"><span class="STYLE10">操作人</span></div></td>
      </tr>
      <tr>
	<c:forEach items="${loggings}" var="l">
	  <tr>
	   	<td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="left">${l.cardno }</div></td>
	   	<td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="left">${l.name }</div></td>
	   	<td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="left">${l.status }</div></td>
        <td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="right" style="color: red;">
        				<c:if test="${l.status eq '消费'}">-</c:if><c:if test="${l.status eq '余额清零'}">-</c:if><fmt:formatNumber value="${l.money }" pattern="##.##" minFractionDigits="2" />&nbsp;</div>
        </td>
        <td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="right">
        				<fmt:formatDate value="${l.date}" pattern="yyyy-MM-dd HH:MM:ss"/>&nbsp;</div>
        </td>
        <td height="20" bgcolor="#FFFFFF" class="STYLE19"><div align="left">${l.operatePerson}</div></td>
	  </tr>
</c:forEach>   	
   
        </div></td>
      </tr>
    </table>
    
    
    
    </td>
  </tr>
  <tr>
    <td height="30">
    <form action="<c:url value='/user/lishi.action'/>">
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td align=right vAlign="center" noWrap>
        <div align="right"><span align="right" class="STYLE22">&nbsp;&nbsp;&nbsp;&nbsp;共有<strong> ${count }</strong> 条记录
        当前第 <strong>${curPage}</strong>页
        共 <strong>${pageNumber}</strong>页
  <a href="<c:url value='/user/lishi.action?cardno=${cardno}&pages=1'/>">第一页</a>
        <c:choose>
			<c:when test="${curPage == 1}">
	    	   	上一页
	    	</c:when>
			<c:otherwise>
				<a href="<c:url value='/user/lishi.action?cardno=${cardno}&pages=${curPage-1}'/>">上一页</a>
			</c:otherwise>
		</c:choose>
		<input type="hidden" id="cardno" name="cardno" value="${cardno}" />
		转到第<input name="pages" type="text" value="${curPage}" size="1"/> <input type="submit" class="buttom" value="页" />
		<c:choose>
			<c:when test="${curPage == pageNumber}">
	    	   	下一页
	    	</c:when>
			<c:otherwise>
				<a href="<c:url value='/user/lishi.action?cardno=${cardno}&pages=${curPage+1}'/>">下一页</a>
			</c:otherwise>
		</c:choose>
		<a href="<c:url value='/user/lishi.action?cardno=${cardno}&pages=${pageNumber}'/>">最后一页</a>
		
		<br><br>
		<input name="return" type="button" class="buttom" value="返回列表页面" onclick="window.location = 'user/showUser.action'"/>
		${msg}
  	    <c:remove var="msg" scope="session"/>
        </span></div></td>
        
      </tr>
    </table>
    </form>
    </td>
  </tr>
</table>
</body>
</html>
